package org.dromara.module.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import jakarta.annotation.Resource;
import lombok.RequiredArgsConstructor;
import org.dromara.module.domain.CnPartner;
import org.dromara.module.mapper.CnPartnerMapper;
import org.dromara.module.service.ICnPartnerService;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 合作伙伴列Service业务层处理
 *
 * @author Lion Li
 * @date 2025-04-07
 */
@RequiredArgsConstructor
@Service
public class CnPartnerServiceImpl extends ServiceImpl<CnPartnerMapper, CnPartner> implements ICnPartnerService {

    @Resource
    private CnPartnerMapper partnerMapper;

    @Override
    public List<CnPartner> getPartnerList() {
        QueryWrapper<CnPartner> qw = new QueryWrapper<>();
        qw.eq("state", 1);
        qw.eq("is_show", 1);
        List<CnPartner> list = partnerMapper.selectList(qw);
        return list;
    }
}
